using System;
using System.Runtime.InteropServices;

namespace XNADash
{
#if WINDOWS || XBOX
    static class Program
    {
        /// <summary>
        /// The main entry point for the application.
        /// </summary>
        static void Main(string[] args)
        {
            using (DashGame game = new DashGame())
            {
                try
                {
                    game.Run();
                }
                catch ( Exception ex )
                {
                    MessageBox( 0, string.Format( "{0}\r\n\r\n{1}", ex.Message, ex.StackTrace ), "Oops!", 0 );
                }
            }
        }

        [DllImport( "user32.dll", CharSet = CharSet.Auto )]
        public static extern uint MessageBox( int hWnd, String text, String caption, uint type );
    }
#endif
}

